package com.by.controller;

import com.by.bean.Specs;
import com.by.bean.query.QuerySpecs;
import com.by.common.core.bean.ResultBean;
import com.by.common.core.controller.BaseController;
import com.by.service.SpecsService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

import static org.bouncycastle.asn1.cmc.CMCStatus.success;

@RestController
@RequestMapping("/specs")

public class SpecsController extends BaseController {
    @Autowired
    SpecsService service;

    @GetMapping("/msg")
    @ApiOperation("搜索specs")
    public ResultBean specsMsg(@RequestBody QuerySpecs querySpecs) {
        List<Specs> ss = service.specsMsg(querySpecs);
        return success("aaa",ss);
    }
}
